package cn._2dland.wolf.jdo;

import javax.jdo.annotations.IdGeneratorStrategy;
import javax.jdo.annotations.IdentityType;
import javax.jdo.annotations.PersistenceCapable;
import javax.jdo.annotations.Persistent;
import javax.jdo.annotations.PrimaryKey;

@PersistenceCapable(identityType = IdentityType.APPLICATION)
public class Village {
	@PrimaryKey
	@Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
	private Long villageId;

	@Persistent
	private String villageName;

	@Persistent
	private int population;

	@Persistent
	private int dayTime;

	@Persistent
	private int nightTime;

	public Village(String villageName, int population, 
			int dayTime, int nightTime){
		super();
		this.villageName = villageName;
		this.population = population;
		this.dayTime = dayTime;
		this.nightTime = nightTime;
	}

	public Long getVillageId() {
		return villageId;
	}

	public String getVillageName() {
		return villageName;
	}

	public int getPopulation() {
		return population;
	}

	public int getDayTime() {
		return dayTime;
	}

	public int getNightTime() {
		return nightTime;
	}

	public void setVillageName(String villageName) {
		this.villageName = villageName;
	}

	public void setPopulation(int population) {
		this.population = population;
	}

	public void setDayTime(int dayTime) {
		this.dayTime = dayTime;
	}

	public void setNightTime(int nightTime) {
		this.nightTime = nightTime;
	}
}
